import Vue from 'vue'
import VueRouter from 'vue-router'
import Home from '../views/Home.vue'
import Login from "@/views/Login";
import AfterloginhomePage from "@/pages/AfterloginhomePage";
import BackstagemanagePage from "@/pages/BackstagemanagePage";
import Backstage2managePage from "@/pages/Backstage2managePage";
import Backstage3managePage from "@/pages/Backstage3managePage";
import Backstage4managePage from "@/pages/Backstage4managePage";
import CustomermanagePage from "@/pages/CustomermanagePage";
import CustomerSearchPage from "@/pages/CustomerSearchPage";
import CustomerLoginPage from "@/pages/CustomerLoginPage";
import CustomerLimitSearchPage from "@/pages/CustomerLimitSearchPage";


Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'Home',
    component: Home
  },
  {
    path: '/afterloginhomePage',
    name: 'AfterloginhomePage',
    component: AfterloginhomePage
  },
  {
    path: '/BackstagemanagePage',
    name: 'BackstagemanagePage',
    component: BackstagemanagePage
  },
  {
    path: '/Backstage2managePage',
    name: 'Backstage2managePage',
    component: Backstage2managePage
  },
  {
    path: '/Backstage3managePage',
    name: 'Backstage3managePage',
    component: Backstage3managePage
  },
  {
    path: '/Backstage4managePage',
    name: 'Backstage4managePage',
    component: Backstage4managePage
  },
  {
    path: '/CustomermanagePage',
    name: 'CustomermanagePage',
    component: CustomermanagePage
  },
  {
    path: '/CustomerSearchPage',
    name: 'CustomerSearchPage',
    component: CustomerSearchPage
  },
  {
    path: '/CustomerLoginPage',
    name: 'CustomerLoginPage',
    component: CustomerLoginPage
  },
  {
    path: '/CustomerLimitSearchPage',
    name: 'CustomerLimitSearchPage',
    component: CustomerLimitSearchPage
  },
  {
    path: '/login',
    name: 'Login',
    // route level code-splitting
    // this generates a separate chunk (about.[hash].js) for this route
    // which is lazy-loaded when the route is visited.
    component: Login
    // component: () => import(/* webpackChunkName: "about" */ '../views/Login.vue')
  }
]

const router = new VueRouter({
  mode: 'history',
  base: process.env.BASE_URL,
  routes
})

export default router
